
package cn.vehicle.service.config;

import java.util.HashMap;
import java.util.Map;

/**
 * 系统配置项定义类
 * <p>
 * 用于集中管理系统级的全局配置项，例如 JWT 安全密钥、Token 过期时间、默认密码等。
 * 所有配置项均通过 {@link SystemConfigItem} 封装，支持类型安全与默认值机制。
 * </p>
 *
 * <p>主要作用：</p>
 * <ul>
 *   <li>统一管理系统常量配置；</li>
 *   <li>方便通过数据库或配置中心动态修改；</li>
 *   <li>提供类型泛化封装，避免手动类型转换。</li>
 * </ul>
 */

public class SystemConfig {

    // JWT 加密密钥配置项：用于生成和验证 Token 的签名密钥
    public final static SystemConfigItem<String> jwtSecurityKey = new SystemConfigItem<>("jwtSecurityKey", "huangjin", String.class);

    // JWT Token 过期时间配置项（单位：毫秒）
    // 默认值为 24 小时（1000*60*60*24）
    public final static SystemConfigItem<Integer> jwtTokenExpireTime = new SystemConfigItem<>("jwtTokenExpireTime", 1000*60*60*24, Integer.class);

    // 系统默认密码配置项：用于初始化新用户或重置密码时的默认值
    public final static SystemConfigItem<String> defaultPassword = new SystemConfigItem<>("defaultPassword", "123456", String.class);
    public final static SystemConfigItem<String> companyCode = new SystemConfigItem<>("companyCode", "123456", String.class);
    public final static SystemConfigItem<String> companyUsername = new SystemConfigItem<>("companyUsername", "123456", String.class);
    public final static SystemConfigItem<String> companyPassword = new SystemConfigItem<>("companyPassword", "123456", String.class);
    public final static SystemConfigItem<String> tjDovEndpoint = new SystemConfigItem<>("tjDovEndpoint", "123456", String.class);
    public final static SystemConfigItem<String> ignoreVehicleNumber = new SystemConfigItem<>("ignoreVehicleNumber", ".*挂.*", String.class);
    public final static SystemConfigItem<String> emissionStandard = new SystemConfigItem<>("emissionStandard", "CN_5", String.class);
    public final static SystemConfigItem<Boolean> transportEntryControl = new SystemConfigItem<>("transportEntryControl", true, Boolean.class);


    public final static SystemConfigItem<Boolean> exitPassValid = new SystemConfigItem<>("exitPassValid", true, Boolean.class);
    public final static SystemConfigItem<Integer> gIoInValueStandard = new SystemConfigItem<>("gIoInValueStandard", 0, Integer.class);
    public final static SystemConfigItem<Integer> gIoInSourceStandard = new SystemConfigItem<>("gIoInSourceStandard", 0, Integer.class);
    public final static SystemConfigItem<String> systemNvrType = new SystemConfigItem<>("systemNvrType", "HIKVISION", String.class);


    public final static SystemConfigItem<String> nvrUsername = new SystemConfigItem<>("nvrUsername", "admin", String.class);
    public final static SystemConfigItem<String> nvrPassword = new SystemConfigItem<>("nvrPassword", "tc123456", String.class);


    public final static SystemConfigItem<String> bindCameraIpMap = new SystemConfigItem<>("bindCameraIpMap", "", String.class);

    public final static SystemConfigItem<Integer> cutVideoDelayTime = new SystemConfigItem<>("cutVideoDelayTime", 0, Integer.class);
    public final static SystemConfigItem<Integer> cutVideoIntervalTime = new SystemConfigItem<>("cutVideoIntervalTime", 0, Integer.class);





}
